/*
 * @Description:
 * @Author: QiangWei
 * @Date: 2019-12-11 17:57:43
 * @LastEditors  : QiangWei
 * @LastEditTime : 2019-12-19 16:25:09
 */
import Vue from 'vue';
import Vuex, { StoreOptions } from 'vuex';
import { RootState } from './types';
import { global } from './global/index';
import { common } from './common/index';

Vue.use(Vuex);

const store: StoreOptions<RootState> = {
  state: {
    version: '1.0.0'
  },
  modules: {
    global,
    common
  }
};

export default new Vuex.Store<RootState>(store);
